{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "https://leetcode.com/problems/design-hashset\n",
    "\n",
    "\n",
    "Runtime: 192 ms, faster than 16.94% of C++ online submissions for Design HashSet.\n",
    "Memory Usage: 42 MB, less than 69.76% of C++ online submissions for Design HashSet.\n",
    "\n",
    "\n",
    "```cpp\n",
    "#include <set>\n",
    "\n",
    "using namespace std;\n",
    "\n",
    "class MyHashSet\n",
    "{\n",
    "public:\n",
    "    /** Initialize your data structure here. */\n",
    "    set<int> mySet;\n",
    "\n",
    "    MyHashSet() {\n",
    "    }\n",
    "\n",
    "    void add(int key) {\n",
    "        mySet.insert(key);\n",
    "    }\n",
    "\n",
    "    void remove(int key) {\n",
    "        mySet.erase(key);\n",
    "    }\n",
    "\n",
    "    /** Returns true if this set contains the specified element */\n",
    "    bool contains(int key) {\n",
    "        return mySet.find(key) != mySet.end();\n",
    "    }\n",
    "};\n",
    "```"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "C++17",
   "language": "C++17",
   "name": "xcpp17"
  },
  "language_info": {
   "codemirror_mode": "text/x-c++src",
   "file_extension": ".cpp",
   "mimetype": "text/x-c++src",
   "name": "c++",
   "version": "17"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 4
}
